<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml" xml:lang="de" lang="de">
<head>
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  <meta http-equiv="content-language" content="de" />
<?php
foreach ($browniepoints->meta() as $name => $content) {
  echo '  <meta name="', $name, '"';
  if (is_array($content)) {
    foreach ($content as $n => $v) {
      echo ' ', $n, '="', addslashes($v), '"';
    }
  }
  else {
    echo ' content="', addslashes($content), '"'; 
  }
  echo " />\n";
}
foreach ($browniepoints->css() as $name => $options) {
  $options += array('media' => 'screen,projection'); 
  if (isset($options['conditional'])) {
    $condition = $options['conditional'];
    unset($options['conditional']);
    echo "  <!--[if {$condition}]>", $html->css($name, NULL, $options), "<![endif]-->\n";
  }
  else {
    echo '  ', $html->css($name, NULL, $options), "\n";
  }
}
foreach ($browniepoints->js() as $name) {
  if (preg_match('/^inline:(.+)$/', $name, $matches)) {
    echo $javascript->codeBlock($this->element($matches[1]));
  }
  else {
    echo ' ', $javascript->link($name), "\n";
  }
}
?>

<?php
/*
?>
  <script type="text/javascript" src="http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php"></script>
  <script type="text/javascript">FB.init("<?php echo $fb_apikey; ?>","/xd_receiver.htm");</script>
<?php
*/
?>

  <title><?php echo $title_for_layout; ?></title>
</head>

<body>
<?php
$session->flash();
$session->flash('auth');
?>
<div id="main">
  <div id="inner">
    <?php echo $this->element('header'); ?>
    <?php echo $content_for_layout; ?>
    <?php echo $this->element('footer'); ?>
  </div><!-- #inner -->
</div><!-- #main -->

</body>
</html>
